package com.cdtye.itps.cms.service.datasysn;

import com.baomidou.dynamic.datasource.annotation.DS;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.cdtye.itps.cms.dao.anchor.vo.JcwAnchorVo;
import com.cdtye.itps.cms.dao.dept.vo.JcDeptSiteVo;
import com.cdtye.itps.cms.dao.dept.vo.SysDeptVo;
import com.cdtye.itps.cms.dao.device.vo.*;
import com.cdtye.itps.cms.dao.dict.vo.SysDictionaryVo;
import com.cdtye.itps.cms.dao.direction.vo.JcDirectionVo;
import com.cdtye.itps.cms.dao.line.vo.JcSeclineVo;
import com.cdtye.itps.cms.dao.lineSite.vo.JcLineSiteVo;
import com.cdtye.itps.cms.dao.pillar.vo.JcwPillarVo;
import com.cdtye.itps.cms.dao.site.vo.JcSiteVo;
import com.cdtye.itps.cms.dao.tunnel.vo.JcTunnelVo;
import com.cdtye.itps.cms.service.anchor.JcwAnchorService;
import com.cdtye.itps.cms.service.dept.JcDeptSiteService;
import com.cdtye.itps.cms.service.dept.SysDeptService;
import com.cdtye.itps.cms.service.device.*;
import com.cdtye.itps.cms.service.dict.SysDictionaryService;
import com.cdtye.itps.cms.service.direction.JcDirectionService;
import com.cdtye.itps.cms.service.line.JcSeclineService;
import com.cdtye.itps.cms.service.lineSite.JcLineSiteService;
import com.cdtye.itps.cms.service.pillar.JcwPillarService;
import com.cdtye.itps.cms.service.site.JcSiteService;
import com.cdtye.itps.cms.service.tunnel.JcTunnelService;
import com.cdtye.itps.models.base.model.vo.basic.PillarVo;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Map;

/**
 * modify by 20250805
 */
@Service
@Slf4j
public class BrainHandleService {

    @Autowired
    private SysDictionaryService sysDictionaryService;

    @Autowired
    private SysDeptService sysDeptService;

    @Autowired
    private JcSeclineService jcSeclineService;

    @Autowired
    private JcDirectionService jcDirectionService;

    @Autowired
    private JcSiteService jcSiteService;

    @Autowired
    private JcLineSiteService jcLineSiteService;

    @Autowired
    private JcDeptSiteService jcDeptSiteService;

    @Autowired
    private JcTunnelService jcTunnelService;

    @Autowired
    private JcwAnchorService jcwAnchorService;

    @Autowired
    private JcwPillarService jcwPillarService;

    @Autowired
    private JcwDevicePillarsService jcwDevicePillarsService;

    @Autowired
    private JcwDeviceService jcwDeviceService;

    @Autowired
    private JcwDeviceclassService jcwDeviceclassService;

    @Autowired
    private JcwDeviceClassPeriodService jcwDeviceClassPeriodService;

    @Autowired
    private JcwPeriodManageService jcwPeriodManageService;

    /**
     * 字典
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String,Object>> pageDictionary(SysDictionaryVo vo) {
        IPage<Map<String,Object>> pages = sysDictionaryService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 部门
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String,Object>> pageDept(SysDeptVo vo) {
        IPage<Map<String,Object>> pages = sysDeptService.pageList4Brain(vo);

        return pages;
    }


    /**
     * 线路
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String,Object>> pageSecline(JcSeclineVo vo) {
        IPage<Map<String,Object>> pages = jcSeclineService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 行别
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String,Object>> pageDirection(JcDirectionVo vo) {
        IPage<Map<String,Object>> pages = jcDirectionService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 区站
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String,Object>> pageSite(JcSiteVo vo) {
        IPage<Map<String,Object>> pages = jcSiteService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 线路区站
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String,Object>> pageLineSite(JcLineSiteVo vo) {
        IPage<Map<String,Object>> pages = jcLineSiteService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 部门区站
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String,Object>> pageDeptSite(JcDeptSiteVo vo) {
        IPage<Map<String,Object>> pages = jcDeptSiteService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 隧道
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String,Object>> pageTunnel(JcTunnelVo vo) {
        IPage<Map<String,Object>> pages = jcTunnelService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 锚段
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String,Object>> pageAnchor(JcwAnchorVo vo) {
        IPage<Map<String,Object>> pages = jcwAnchorService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 支柱
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String, Object>> pagePillar(JcwPillarVo vo) {
        IPage<Map<String,Object>> pages = jcwPillarService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 设备支柱
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String, Object>> pageDevicePillars(JcwDevicePillarsVo vo) {
        IPage<Map<String,Object>> pages = jcwDevicePillarsService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 设备
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String, Object>> pageDevice(JcwDeviceVo vo) {
        IPage<Map<String,Object>> pages = jcwDeviceService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 设备分类
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String, Object>> pageDeviceclass(JcwDeviceclassVo vo) {
        IPage<Map<String,Object>> pages = jcwDeviceclassService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 设备周期
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String, Object>> pageDeviceClassPeriod(JcwDeviceClassPeriodVo vo) {
        IPage<Map<String,Object>> pages = jcwDeviceClassPeriodService.pageList4Brain(vo);

        return pages;
    }

    /**
     * 检测周期
     * @param vo
     * @return
     */
    @DS("tmis")
    public IPage<Map<String, Object>> pagePeriodManage(JcwPeriodManageVo vo) {
        IPage<Map<String,Object>> pages = jcwPeriodManageService.pageList4Brain(vo);

        return pages;
    }
}
